<?php

namespace Home\Dao;
use Think\Model\BaseDao;

class SchoolDao extends BaseDao{

    protected $_map = array(
        'add_sch_id' => 'sch_id',
        'add_sch_name' => 'sch_name',
        'add_sch_office' => 'sch_office',
        'add_tea_boss' => 'tea_id',
        'add_sch_intro' => 'sch_intro',
        'edit_sch_id' => 'sch_id',
        'edit_sch_name' => 'sch_name',
        'edit_sch_office' => 'sch_office',
        'edit_tea_boss' => 'tea_id',
        'edit_sch_intro' => 'sch_intro',
        'delete_sch_id' => 'sch_id'
    );

    protected $_validate = array(
        array('sch_id','require','学院编号不能为空'),
        array('sch_name','require','学院名称不能为空'),
        array('sch_office','require','办公地点不能为空'),
        array('tea_id','0','请选择院长',0,'notequal'),
        array('sch_intro','require','学院简介不能为空'),
    );






}


?>